<HTML>
<HEAD>
<TITLE>xpm2ps</TITLE>
<LINK rel=stylesheet href="style.css" type="text/css">
<BODY text="#000000" bgcolor="#FFFFFF" link="#0000FF" vlink="#990000" alink="#FF0000">
<TABLE WIDTH="98%" NOBORDER >
<TR><TD WIDTH=400>
<TABLE WIDTH=400 NOBORDER>
<TD WIDTH=116>
<a href="http://www.gromacs.org/"><img SRC="../images/gmxlogo_small.png"BORDER=0 </a></td>
<td ALIGN=LEFT VALIGN=TOP WIDTH=280><br><h2>xpm2ps</h2><font size=-1><A HREF="../online.html">Main Table of Contents</A></font><br><br></td>
</TABLE></TD><TD WIDTH="*" ALIGN=RIGHT VALIGN=BOTTOM><p><B>VERSION 4.5<br>
Thu 26 Aug 2010</B></td></tr></TABLE>
<HR>
<H3>Description</H3>
<p>
xpm2ps makes a beautiful color plot of an XPixelMap file.
Labels and axis can be displayed, when they are supplied
in the correct matrix format.
Matrix data may be generated by programs such as <a href="do_dssp.html">do_dssp</a>, <a href="g_rms.html">g_rms</a> or
<a href="g_mdmat.html">g_mdmat</a>.<p>
Parameters are set in the <tt><a href="m2p.html">m2p</a></tt> file optionally supplied with
<tt>-di</tt>. Reasonable defaults are provided. Settings for the y-axis
default to those for the x-axis. Font names have a defaulting hierarchy:
titlefont -&gt; legendfont; titlefont -&gt; (xfont -&gt; yfont -&gt; ytickfont)
-&gt; xtickfont, e.g. setting titlefont sets all fonts, setting xfont
sets yfont, ytickfont and xtickfont.<p>
When no <tt><a href="m2p.html">m2p</a></tt> file is supplied, many setting are set by
command line options. The most important option is <tt>-size</tt>
which sets the size of the whole matrix in postscript units.
This option can be overridden with the <tt>-bx</tt> and <tt>-by</tt>
options (and the corresponding parameters in the <tt><a href="m2p.html">m2p</a></tt> file),
which set the size of a single matrix element.<p>
With <tt>-f2</tt> a 2nd matrix file can be supplied, both matrix
files will be read simultaneously and the upper left half of the
first one (<tt>-f</tt>) is plotted together with the lower right
half of the second one (<tt>-f2</tt>). The diagonal will contain
values from the matrix file selected with <tt>-diag</tt>.
Plotting of the diagonal values can be suppressed altogether by
setting <tt>-diag</tt> to <tt>none</tt>.
In this case, a new color <a href="map.html">map</a> will be generated with
a red gradient for negative numbers and a blue for positive.
If the color coding and legend labels of both matrices are identical,
only one legend will be displayed, else two separate legends are
displayed.
With <tt>-combine</tt> an alternative operation can be selected
to combine the matrices. The output range is automatically set
to the actual range of the combined matrix. This can be overridden
with <tt>-cmin</tt> and <tt>-cmax</tt>.<p>
<tt>-title</tt> can be set to <tt>none</tt> to suppress the title, or to
<tt>ylabel</tt> to show the title in the Y-label position (alongside
the Y-axis).<p>
With the <tt>-rainbow</tt> option dull grey-scale matrices can be turned
into attractive color pictures.<p>
Merged or rainbowed matrices can be written to an XPixelMap file with
the <tt>-<a href="xpm.html">xpm</a></tt> option.
<P>
<H3>Files</H3>
<TABLE BORDER=1 CELLSPACING=0 CELLPADDING=2>
<TR><TH>option</TH><TH>filename</TH><TH>type</TH><TH>description</TH></TR>
<TR><TD ALIGN=RIGHT> <b><tt>-f</tt></b> </TD><TD ALIGN=RIGHT> <tt><a href="xpm.html">    root.xpm</a></tt> </TD><TD> Input </TD><TD> X PixMap compatible matrix file </TD></TR>
<TR><TD ALIGN=RIGHT> <b><tt>-f2</tt></b> </TD><TD ALIGN=RIGHT> <tt><a href="xpm.html">   root2.xpm</a></tt> </TD><TD> Input, Opt. </TD><TD> X PixMap compatible matrix file </TD></TR>
<TR><TD ALIGN=RIGHT> <b><tt>-di</tt></b> </TD><TD ALIGN=RIGHT> <tt><a href="m2p.html">      ps.m2p</a></tt> </TD><TD> Input, Opt., Lib. </TD><TD> Input file for mat2ps </TD></TR>
<TR><TD ALIGN=RIGHT> <b><tt>-do</tt></b> </TD><TD ALIGN=RIGHT> <tt><a href="m2p.html">     out.m2p</a></tt> </TD><TD> Output, Opt. </TD><TD> Input file for mat2ps </TD></TR>
<TR><TD ALIGN=RIGHT> <b><tt>-o</tt></b> </TD><TD ALIGN=RIGHT> <tt><a href="eps.html">    plot.eps</a></tt> </TD><TD> Output, Opt. </TD><TD> Encapsulated PostScript (tm) file </TD></TR>
<TR><TD ALIGN=RIGHT> <b><tt>-xpm</tt></b> </TD><TD ALIGN=RIGHT> <tt><a href="xpm.html">    root.xpm</a></tt> </TD><TD> Output, Opt. </TD><TD> X PixMap compatible matrix file </TD></TR>
</TABLE>
<P>
<H3>Other options</H3>
<TABLE BORDER=1 CELLSPACING=0 CELLPADDING=2>
<TR><TH>option</TH><TH>type</TH><TH>default</TH><TH>description</TH></TR>
<TR><TD ALIGN=RIGHT> <b><tt>-[no]h</tt></b> </TD><TD ALIGN=RIGHT> gmx_bool </TD><TD ALIGN=RIGHT> <tt>no    </tt> </TD><TD> Print help info and quit </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-[no]version</tt></b> </TD><TD ALIGN=RIGHT> gmx_bool </TD><TD ALIGN=RIGHT> <tt>no    </tt> </TD><TD> Print version info and quit </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-nice</tt></b> </TD><TD ALIGN=RIGHT> int </TD><TD ALIGN=RIGHT> <tt>0</tt> </TD><TD> Set the nicelevel </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-[no]w</tt></b> </TD><TD ALIGN=RIGHT> gmx_bool </TD><TD ALIGN=RIGHT> <tt>no    </tt> </TD><TD> View output <a href="xvg.html">xvg</a>, <a href="xpm.html">xpm</a>, <a href="eps.html">eps</a> and <a href="pdb.html">pdb</a> files </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-[no]frame</tt></b> </TD><TD ALIGN=RIGHT> gmx_bool </TD><TD ALIGN=RIGHT> <tt>yes   </tt> </TD><TD> Display frame, ticks, labels, title and legend </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-title</tt></b> </TD><TD ALIGN=RIGHT> enum </TD><TD ALIGN=RIGHT> <tt>top</tt> </TD><TD> Show title at: <tt><a href="top.html">top</a></tt>, <tt>once</tt>, <tt>ylabel</tt> or <tt>none</tt> </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-[no]yonce</tt></b> </TD><TD ALIGN=RIGHT> gmx_bool </TD><TD ALIGN=RIGHT> <tt>no    </tt> </TD><TD> Show y-label only once </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-legend</tt></b> </TD><TD ALIGN=RIGHT> enum </TD><TD ALIGN=RIGHT> <tt>both</tt> </TD><TD> Show legend: <tt>both</tt>, <tt>first</tt>, <tt>second</tt> or <tt>none</tt> </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-diag</tt></b> </TD><TD ALIGN=RIGHT> enum </TD><TD ALIGN=RIGHT> <tt>first</tt> </TD><TD> Diagonal: <tt>first</tt>, <tt>second</tt> or <tt>none</tt> </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-size</tt></b> </TD><TD ALIGN=RIGHT> real </TD><TD ALIGN=RIGHT> <tt>400   </tt> </TD><TD> Horizontal size of the matrix in ps units </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-bx</tt></b> </TD><TD ALIGN=RIGHT> real </TD><TD ALIGN=RIGHT> <tt>0     </tt> </TD><TD> Element x-size, overrides -size (also y-size when -by is not set) </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-by</tt></b> </TD><TD ALIGN=RIGHT> real </TD><TD ALIGN=RIGHT> <tt>0     </tt> </TD><TD> Element y-size </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-rainbow</tt></b> </TD><TD ALIGN=RIGHT> enum </TD><TD ALIGN=RIGHT> <tt>no</tt> </TD><TD> Rainbow colors, convert white to: <tt>no</tt>, <tt>blue</tt> or <tt>red</tt> </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-gradient</tt></b> </TD><TD ALIGN=RIGHT> vector </TD><TD ALIGN=RIGHT> <tt>0 0 0</tt> </TD><TD> Re-scale colormap to a smooth gradient from white {1,1,1} to {r,g,b} </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-skip</tt></b> </TD><TD ALIGN=RIGHT> int </TD><TD ALIGN=RIGHT> <tt>1</tt> </TD><TD> only write out every nr-th row and column </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-[no]zeroline</tt></b> </TD><TD ALIGN=RIGHT> gmx_bool </TD><TD ALIGN=RIGHT> <tt>no    </tt> </TD><TD> insert line in <a href="xpm.html">xpm</a> matrix where axis label is zero </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-legoffset</tt></b> </TD><TD ALIGN=RIGHT> int </TD><TD ALIGN=RIGHT> <tt>0</tt> </TD><TD> Skip first N colors from <a href="xpm.html">xpm</a> file for the legend </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-combine</tt></b> </TD><TD ALIGN=RIGHT> enum </TD><TD ALIGN=RIGHT> <tt>halves</tt> </TD><TD> Combine two matrices: <tt>halves</tt>, <tt>add</tt>, <tt>sub</tt>, <tt>mult</tt> or <tt>div</tt> </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-cmin</tt></b> </TD><TD ALIGN=RIGHT> real </TD><TD ALIGN=RIGHT> <tt>0     </tt> </TD><TD> Minimum for combination output </TD></TD>
<TR><TD ALIGN=RIGHT> <b><tt>-cmax</tt></b> </TD><TD ALIGN=RIGHT> real </TD><TD ALIGN=RIGHT> <tt>0     </tt> </TD><TD> Maximum for combination output </TD></TD>
</TABLE>
<P>
<hr>
<div ALIGN=RIGHT>
<font size="-1"><a href="http://www.gromacs.org">http://www.gromacs.org</a></font><br>
<font size="-1"><a href="mailto:gromacs@gromacs.org">gromacs@gromacs.org</a></font><br>
</div>
</BODY>
